 package org.mybatis.plugin;

public class MySqlIbatisDialect extends IbatisDialect
 {
   public boolean supportsLimit()
   {
     return true;
   }
 
   public boolean supportsLimitOffset() {
     return true;
   }
 
   public String getLimitString(String sql, int offset, String offsetPlaceholder, int limit, String limitPlaceholder)
   {
     if (offset > 0) {
       sql = sql + " limit " + offsetPlaceholder + "," + limitPlaceholder;
     }
     else {
       sql = sql + " limit " + limitPlaceholder;
     }
     return sql;
   }
 }

